﻿#nullable enable

using NewRetail.Application.Core.Entity;

namespace NewRetail.Application.Components.WeChat.Member.Entity
{
    public class WeChatMember : BaseEntityWithNo
    {
        /// <summary>
        /// 获取或设置用户被打上的标签 ID 列表
        /// </summary>
        public int[]? TagIdList { get; set; }
        /// <summary>
        /// 获取或设置用户所在的分组 ID（兼容旧的用户分组接口）
        /// </summary>
        public int GroupId { get; set; }
        /// <summary>
        /// 获取或设置公众号运营者对粉丝的备注
        /// </summary>
        public string? Remark { get; set; }
        /// <summary>
        /// 获取或设置用户关注的渠道来源
        /// </summary>
        public string? SubscribeScene { get; set; }
        /// <summary>
        /// 获取或设置用户关注的时间戳。如果用户曾多次关注，则取最后关注时间。
        /// </summary>
        public long? SubscribeTimestamp { get; set; }
        /// <summary>
        /// 获取或设置用户是否订阅该公众号标识
        /// </summary>
        [Newtonsoft.Json.JsonConverter(typeof(Newtonsoft.Json.Converters.NumericalBooleanConverter))]
        [System.Text.Json.Serialization.JsonConverter(typeof(System.Text.Json.Converters.NumericalBooleanConverter))]
        public bool IsSubscribed { get; set; }
        /// <summary>
        /// 获取或设置用户的头像 URL
        /// </summary>
        public string? HeadImageUrl { get; set; }
        /// <summary>
        /// 获取或设置用户的语言
        /// </summary>
        public string? Language { get; set; }
        /// <summary>
        /// 获取或设置用户所在城市
        /// </summary>
        public string? City { get; set; }
        /// <summary>
        /// 获取或设置用户所在省份
        /// </summary>
        public string? Province { get; set; }
        /// <summary>
        /// 获取或设置用户所在国家
        /// </summary>
        public string? Country { get; set; }
        /// <summary>
        /// 获取或设置用户的性别
        /// </summary>
        public int? Sex { get; set; }
        /// <summary>
        /// 获取或设置用户的昵称
        /// </summary>
        public string? Nickname { get; set; }
        /// <summary>
        /// 获取或设置用户全局标识。只有在用户将公众号绑定到微信开放平台帐号后，才会出现该字段。
        /// </summary>
        public string? UnionId { get; set; }
        /// <summary>
        /// 获取或设置用户唯一标识
        /// </summary>
        public string OpenId { get; set; } = null!;
        /// <summary>
        /// 获取或设置二维码扫码场景值 ID。
        /// </summary>
        public long? QrcodeSceneId { get; set; }
        /// <summary>
        /// 获取或设置二维码扫码场景描述
        /// </summary>
        public string? QrcodeSceneString { get; set; }
    }
}
